Recursion: Stack Size with DOORS 9.6.0.1

Has anybody experienced process crashes after migrating from DOORS 9.5 to client 9.6.0.1 (64bit)?

I am currently fixing my DXL code after upgrading the client to 9.6 and besides Mathias Mamsch's StringTable64 (huzzah, it appears to work), I have at least two other problems. I just isolated a second crash cause (DOORS client application crashes without DXL error message, only showing the MS-Windows message dialogue which states that the process terminated abnormally) which was a recursive algorithm. In both cases, the depth is not too high. It's a mere bubble sort on a Skip list with approx 60 elements. It crashes at dept 47, after creating some local objects, just when entering a for-loop iterating over the Skip list which contains the remaining unsorted elements. When crashing, the process consumes approx 337 MByte of memory. I believe I increased the stack size by using

pragma stack, 10000000

So what could have gone wrong? The first crash cause was eliminated by replacing the recursion by a plain loop construct. Now it works, but that's ridiculous!


Twonky - Mon Aug 08 12:12:58 EDT 2016

Re: Recursion: Stack Size with DOORS 9.6.0.1
DOORSHAM - Mon Aug 08 12:23:53 EDT 2016

I have notice that doors 9.6 has included a bug associated with translating structures --  I have had to change old dxl to get around the introduced bug.

IBM is again trying to drive people away from doors so they can make more money.

Re: Recursion: Stack Size with DOORS 9.6.0.1
a8155058 - Tue Aug 09 12:30:48 EDT 2016

using a bubble sort for real?  if so, hand over your keyboard to us. Laughing

Re: Recursion: Stack Size with DOORS 9.6.0.1
Twonky - Tue Aug 09 13:12:36 EDT 2016

a8155058 - Tue Aug 09 12:30:48 EDT 2016

using a bubble sort for real?  if so, hand over your keyboard to us. Laughing

Seriously! I'm sorting entries of a glossary for PDF export. So, if bubble sort is too slow, I have got bigger problems because our customer will complain or simply stop turning pages. Tongue

But seriously, I converted the sort from recursive to non-recursive and it works. Did I mention that this is ridiculous? Will we lose for-loops or Skip lists when they introduce DOORS 9.7?

Re: Recursion: Stack Size with DOORS 9.6.0.1
DOORSHAM - Tue Aug 09 13:58:15 EDT 2016

If you do it right -- a skip list can sort itself.

Re: Recursion: Stack Size with DOORS 9.6.0.1
Wolfgang Uhr - Thu Aug 11 07:03:01 EDT 2016

DOORSHAM - Tue Aug 09 13:58:15 EDT 2016

If you do it right -- a skip list can sort itself.

He is not right. Bubblesort is one of the things you really do not need in dxl. It is absolute correct that the program crashes.

 

Skip skpSort = createString();

put (skpSort, "001", "one");
put (skpSort, "003", "three");
put (skpSort, "002", "two");


string sElement;
for sElement in skpSort do {
   print sElement "\n";
}

have fun

Re: Recursion: Stack Size with DOORS 9.6.0.1
Mathias Mamsch - Sat Aug 20 05:47:42 EDT 2016

Twonky - Tue Aug 09 13:12:36 EDT 2016

Seriously! I'm sorting entries of a glossary for PDF export. So, if bubble sort is too slow, I have got bigger problems because our customer will complain or simply stop turning pages. Tongue

But seriously, I converted the sort from recursive to non-recursive and it works. Did I mention that this is ridiculous? Will we lose for-loops or Skip lists when they introduce DOORS 9.7?

If you get these kinds of crashes, then this is more likely a "oh I put a reference inside a skip list instead of a value" problem or maybe a "oh my program run in an endless loop while sorting" problem. These kinds of crashes you usually get, when you do:

void func() { func(); }

I cannot believe there is something wrong with the stack size inside the DOORS interpreter or that you cannot implement a bubble sort on skips. If you still have the recursive code and post it we can check.

Regards, Mathias